(##) Proposed features and points
- Parellization with Nanothread (2 points)
- Intels Open Image Denoise Integration (3 points)
- More Efficient BVH (SBVH) (4 points)
- Photon Mapping (8 points)
(##) Parellization with Nanothread
- Ray Tracing
The raytrace method generates an image by tracing rays through the scene for every pixel which is parallelizable since each pixel can be computed independently. The height of the image is divided into smaller blocks, and each thread processes one block.
Rendering time improved by factor of 3.
- BBH construction
When creating the BBH, the workload of dividing surfaces and creating child nodes is parallelized using drjit::parallel_for.
The left and right children of a BBH node are constructed in separate threads.
Introducing multithreading improved the building of BBH tree by a factor between 2-5.
- Denoising
The input buffer assignment (colorPtr, albedoPtr, etc.) is performed in parallel using drjit::parallel_for. Each thread processes a block of rows.
Writing back the results to the image from the output buffer is parallelized similarly to the input buffer population.
(##) SBVH
is an enhancement of BVH that incorporates spatial splits into the hierarchy construction. Unlike standard BVH, which partitions surfaces purely based on their centroid locations, SBVH also considers splitting the space itself, subdividing objects that span across multiple regions in a bounding box.
The node evaluates splitting the surfaces along various axes using Surface Area Heuristic (SAH):
1- Iterate Over Axes: For each axis (x, y, z), the surfaces are sorted by their bounding box centers.
2- Evaluate SAH Costs: Compute SAH cost for potential splits by dividing surfaces into left and right sets:
3- Choose Best Split: The split with the lowest SAH cost is selected, and the surfaces are divided into left and right children.
When surfaces overlap multiple bounding boxes, spatial splits subdivide the space itself, slicing the bounding box and splitting surfaces into fragments.
My challenge was to render granular particles. The construction of bbh for my scene improved 5x and rendering time improved by 3x for 2048 samples compared to SAH.
Fewer Ray-Surface Intersections: Tighter bounding boxes reduce the number of surfaces checked for ray intersection.
Lower Traversal Costs: Balanced splits minimize the depth of the hierarchy, reducing traversal overhead.
Efficient for Dense and Overlapping Particles: Spatial splits handle overlapping particles better than centroid-based splits.
Below are the comparisions with split methods.
1-Fixed axis per level
2- Longest axis
3- Random axis
4-SAH
5-SBVH
(##) Denoising -
Here are few examples of the Intels Open Image Denoise Integration.
(##) Photon Mapping
is a two-pass global illumination technique for simulating complex light interactions like caustics, indirect illumination, and color bleeding. It works by:
Photon Emission and Storage: Light sources emit photons that interact with the scene. Photons are stored in a photon map at surfaces they interact with.
Photon Gathering: During rendering, nearby photons are used to estimate radiance at intersection points.
Few errors which i got during the process.
Final Render